package com.egdigital.allzic.data.object;

import android.os.Parcel;
import android.os.Parcelable;

public class Department implements Parcelable {

	private String	mId;
	private String	mTitle;

	public Department(String id, String title) {
		mId = id;
		mTitle = title;
	}

	public String getId() {
		return mId;
	}

	public void setId(String id) {
		mId = id;
	}

	public String getTitle() {
		return mTitle;
	}

	public void setTitle(String title) {
		mTitle = title;
	}

	@Override
	public String toString() {
		return String.format("%s %s \n", mId, mTitle);
	}

	/**
	 * parcel
	 */
	public Department(Parcel parcel) {
		mId = parcel.readString();
		mTitle = parcel.readString();
	}

	public int describeContents() {
		// not used
		return 0;
	}

	public void writeToParcel(Parcel dest, int flags) {
		dest.writeString(mId);
		dest.writeString(mTitle);
	}

	public static Creator<Department>	CREATOR	= new Creator<Department>() {

													public Department createFromParcel(Parcel parcel) {
														return new Department(parcel);
													}

													public Department[] newArray(int size) {
														return new Department[size];
													}
												};
}
